package com.feng.annotation.property;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

/**
 * @author Lee
 * @date 2019/3/6
 */
@Data
@ToString
@PropertySource(value = {"classpath:db.properties"})
@NoArgsConstructor
@AllArgsConstructor
@Component
public class DataSourceProperty {

    @Value("${druid.username}")
    private String username;

    @Value("${druid.password}")
    private String password;

    @Value("${druid.url}")
    private String url;

    @Value("${druid.driverClass}")
    private String driverClass;

}
